#include <opencv2\core\core.hpp>
#include <opencv2\highgui\highgui.hpp>
#include <opencv2\imgproc\imgproc.hpp>
#include <iostream>
#include "myOpenCVLIB\myheader.h"

using namespace std;  
using namespace cv; 


void showImg(Mat img, char * name){
	namedWindow(name);
	imshow(name,img);
	waitKey();
}

int main(){

	Mat img, imgGray, dst;

	int kernelSize = 3;
	int scale = 1;
	int delta = 0;
	int depth = CV_16S;

	img = imread(LENA);

	showImg(img, "img");


	GaussianBlur(img, img,Size(3,3),0,0,BORDER_DEFAULT);

	showImg(img, "GaussianBlur");

	cvtColor(img,imgGray,CV_RGBA2GRAY);

	showImg(imgGray, "imgGray");

	Mat absDst;

	Laplacian(imgGray, dst,depth, kernelSize, scale, delta, BORDER_DEFAULT);

	showImg(dst, "dst");

	convertScaleAbs(dst, absDst);

	showImg(absDst, "absDst");
	
	return 0;
}